/**
 * NearShop
 * ShopDetailAction.java
 * com.android.nearshop.io.protocol.in
 * 
 */
package com.android.nearshop.io.protocol.in;

import com.android.nearshop.io.protocol.out.ShopDetail;

import android.util.Log;

/*********************************************************
 * @author : zhaohua
 * @version : 2012-8-11
 * @see : 根据参数，查询商家详情信息。
 * @Copyright : copyrights reserved by personal 2007-2012
 **********************************************************/
public class ShopDetailAction extends SoapAction<ShopDetail>
{
    /**
     * 查询商家详情信息
     * @param shopId 商家Id
     * @param commNums 详情页面返回的评论数目
     */
    public ShopDetailAction(int shopId, int commNums)
    {
        super(ACTION_TYPE.ACTION_SHOP,"shopDetail");
        addJsonParam("shopId", shopId+"");
        addJsonParam("commNums", commNums+"");
    }
    
    
    /* (non-Javadoc)
     * @see com.android.nearshop.io.protocol.in.SoapAction#parseJson(java.lang.String)
     */
    @Override
    protected ShopDetail parseJson(String response) throws Exception
    {
        Log.d(getMethod(), getMethod() + "response: \n " + response);
        ShopDetail res = new ShopDetail();
        res.parseData(response);
        return res;
    }

}
